home *** CD-ROM | disk | FTP | other *** search
/ The Atari Compendium / The Atari Compendium (Toad Computers) (1994).iso / files / prgtools / mint / utilit~1 / gdb35src.zoo / dist-gdb / atariwait.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-03-10  |  371 b   |  18 lines

  1. #include <mintbind.h>
  2. #include <atarierr.h>
  3. #include <stdio.h>
  4. #include "wait.h"
  5.  
  6. /* we try to fake this... */
  7. long _stksize=1024*1024;
  8.  
  9. int wait(int *x)
  10. {
  11.     int retcode;
  12.     
  13.     retcode=Pwait3(0x02,0L);
  14.     if(retcode==EFILNF) { fprintf(stderr,"No child to Pwait3() for!\n"); fflush(stderr); }
  15.     if(x!=NULL)*x=retcode;
  16.     return retcode>>16; /* here's the pid */
  17. }
  18.